// @ts-ignore
/* eslint-disable */
import request from '@/request'

/** addLeave POST /api/leave/addLeave */
export async function addLeaveUsingPost(
  body: API.LeaveAddRequest,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>('/api/leave/addLeave', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** getLeavePage POST /api/leave/getLeavePage */
export async function getLeavePageUsingPost(
  body: API.LeaveQueryRequest,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponsePageLeaveVo_>('/api/leave/getLeavePage', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** getLeaveInfo GET /api/leave/getUserLeaveInfo */
export async function getLeaveInfoUsingGet(options?: { [key: string]: any }) {
  return request<API.BaseResponseListLeaveVo_>('/api/leave/getUserLeaveInfo', {
    method: 'GET',
    ...(options || {}),
  })
}

/** doLeaveReview POST /api/leave/review */
export async function doLeaveReviewUsingPost(
  body: API.LeaveReviewRequest,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>('/api/leave/review', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** listPictureTagCategory GET /api/leave/tag_category */
export async function listPictureTagCategoryUsingGet(options?: { [key: string]: any }) {
  return request<API.BaseResponseLeaveTagCategory_>('/api/leave/tag_category', {
    method: 'GET',
    ...(options || {}),
  })
}
